home *** CD-ROM | disk | FTP | other *** search
/ NetNews Offline 2 / NetNews Offline Volume 2.iso / news / comp / lang / c++-part2 / 12039 < prev    next >
Encoding:
Internet Message Format  |  1996-08-05  |  1007 b 

  1. Path: news1.erols.com!newsmaster@erols.com
  2. From: Chris Cobb <ccobb@cseg.com>
  3. Newsgroups: comp.lang.c++
  4. Subject: Re: extern consts
  5. Date: 17 Mar 1996 23:34:01 GMT
  6. Organization: CSEG, Inc.
  7. Message-ID: <4ii7h9$bq6@news6.erols.com>
  8. References: <4idbcv$ue2@news7.erols.com> <314c2077.138956468@nntp.ix.netcom.com>
  9. NNTP-Posting-Host: ccobb.erols.com
  10. Mime-Version: 1.0
  11. Content-Type: text/plain; charset=us-ascii
  12. Content-Transfer-Encoding: 7bit
  13. X-Mailer: Mozilla 1.22KIT (Windows; U; 16bit)
  14.  
  15. miker3@ix.netcom.com (Mike Rubenstein) wrote:
  16. >
  17. >It's not legal.  extern const is legal, but in any compilation unit
  18. >that does not see the initializer the const variable is not a constant
  19. >expression.
  20. >
  21.  
  22. Well, your comment makes sense.  However, in a way it seem 
  23. self-contradictory.  If a const can be extern, then it no longer is a 
  24. const: you've basically externed away constness.  But if thats what 
  25. externinig a const does, it doesn't make sense to allow it at all (which 
  26. is what happens on most compilers.)
  27.  
  28. Chris
  29.  
  30.  
  31.